<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8">
    <title>用户信息的主页</title>
    <style>
        .tb{
            border: none;
            border-collapse: collapse;
            width: 400px;
        }
        .tb td{
            border:1px solid #000;
            line-height: 30px;
        }
    </style>
    <script th:src="@{/js/jquery.min.js}"></script>
    <script th:inline="javascript">var ctx = [[@{/}]];</script>
    <script>
        $(function(){
            $.ajax({
               type:'post',
               url:ctx+'uc/fu',
               dataType:'json',
               success:function (result) {
                   $.each(result,function (i,res) {
                       var str = '<tr>' +
                               '<td>'+res.name+'</td>' +
                               '<td>'+res.idcard+'</td>' +
                               '<td>'+res.loginName+'</td>' +
                               '<td>'+res.password+'</td>' +
                               '<td>操作</td>' +
                           '</tr>';

                       $('table[class="tb"]').append(str);
                   })
               } 
            });
        })
    </script>
</head>
<body>
    <center>
        <table class="tb">
            <tr>
                <td>姓名</td>
                <td>身份证号码</td>
                <td>登录名</td>
                <td>密码</td>
                <td>操作</td>
            </tr>

        </table>
    </center>
</body>
</html>